<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <title>get()方法</title>
</head>

<body>
    <div id="app">
        <button @click="fnget">Get方法</button>
    </div>
</body>

</html>
<script src="https://cdn.bootcss.com/vue/2.6.11/vue.min.js"></script>
<script src="https://unpkg.com/axios/dist/axios.min.js"></script>
<script>
    var app = new Vue({
        el: '#app',
        methods: {
            fnget() {
                /* url后面拼接需要跨域的连接即可 */
                axios.get("http://www.baidu.com/?url=111111?name=2222").then(function (res) {
                    console.log(res);
                }, function (err) {
                    console.log(err);
                })
            }
        }
    })
</script>